import os
from openai import OpenAI

client = OpenAI(
    # 从环境变量中读取您的方舟API Key
    api_key='37479a55-929e-40c5-9892-8c2c41e9315a1',
    base_url="https://ark.cn-beijing.volces.com/api/v3",
    )
response = client.chat.completions.create(
    # 替换 <YOUR_ENDPOINT_ID> 为您的方舟推理接入点 ID
    model="ep-20250204233110-r7lm2",
    messages=[
        {"role": "user", "content": "蔚来的现金流能支持多久"}
    ]
)

print(response.choices[0].message)
print(response.choices[0].message.content)